package com.future.bantang.activity;

import android.view.View;
import android.widget.EditText;
import android.widget.ImageView;
import com.future.bantang.R;
import com.future.bantang.fragment.SearchCategoryFragment;
import com.lidroid.xutils.view.annotation.ContentView;
import com.lidroid.xutils.view.annotation.ViewInject;
import com.lidroid.xutils.view.annotation.event.OnClick;

/**
 * Created by zzh on 2016/1/14.
 *
 * 搜索
 *
 * 默认显示分类（SearchCategoryFragment.java），
 * 点击搜索框后显示搜索历史和热门搜索（SearchHistoryHotFragment.java），
 * 输入关键字后显示搜索结果(SearResultFragment.java)
 */

@ContentView(R.layout.activity_search)
public class SearchActivity extends BaseActivity{

    @ViewInject(R.id.img_search_back)
    private ImageView icBak;

    @ViewInject(R.id.edit_activity_search_search_box)
    private EditText searchBox;

    @OnClick(R.id.img_search_back)
    private void icBakClick(View view){
        this.finish();
    }

    @Override
    protected void init() {
        //默认显示分类
        showFragment(R.id.relative_activity_search, SearchCategoryFragment.class);

        //点击输入框就显示SearchHistoryHotFragment.java

        //输入文字就显示SearResultFragment.java


    }

    @Override
    protected void loadDatas() {
        super.loadDatas();
    }
}
